{% extends "base.html" %}
{% block title %}
{{ picture.title }}
{% endblock %}

{%block home_class_text%}{%endblock%}
{%block photos_class_text%}class="current_page_item"{%endblock%}

{%block page_title%}{{ picture.title }}{%endblock%}

{%block posted_by%}<p><small>Posted by {{ picture.author }} at {{picture.date|date:"M d, Y f a T"}}</small></p>{%endblock%}

{% block maincontent %}
<p><a href="{% url views.originalimage picture.rawImage.key.id %}" title="click to see original size">
<img src="{% url views.rawimage picture.key.id %}"/></a>
</p>

<p><b>COMMENTS:</b><br/>
<div>
{% for comment in comments %}
<p class="comment">{{comment.content}}<br/>Posted by: {{comment.author}} at {{comment.date|date:"M d, Y f a T"}}</p>
{% endfor %}
</div>
</p>
<div class="commentform">
{%if user%}
<form action="{% url views.addcomment picture.key.id %}" method="POST">
<b>POST A COMMENT</b><br/>
{{commentForm.content}}
<br/>
<input type="submit"/>
</form>
{%else%}
<b>POST A COMMENT</b> (you will need to <a href="{{ user_url }}">sign in with your Google Account</a>)<br/>
{%endif%}
</div>
</p>
{% endblock %}
